package com.briup.demo.dao;

import com.briup.demo.bean.role_privilege;
import org.apache.ibatis.annotations.Delete;
import org.apache.ibatis.annotations.Insert;
import org.apache.ibatis.annotations.Select;
import org.apache.ibatis.annotations.Update;

import java.util.List;

public interface role_privilegeMapper {
    @Select("select * from role_privilege")
    List<role_privilege> selectAll();
    @Insert("insert into role_privilege values(null,#{role_id},#{privilege_id})")
    void insert (role_privilege privilege);
    @Update("update role_privilege set role_id=#{role_id},privilege_id=#{privilege_id} where id=#{id}")
    void update (role_privilege privilege);
    @Delete("delete from role_privilege where id = #{id}")
    void delete (Long id);
}
